package com.dmzc.addon;

public class TestCoprime {
    public static void main(String[] args) {
        int max = 78;
        int min = 45;
        int mod;
        //判断两个数是不是互质
//        317/52=6....5
//                52/5=10.....2
//                    5/2=2....1
        while (min != 1) {
            System.out.println("max:" + max + "---" + min);
            if ((mod = max % min) == 0) {
                break;
            }
            max = min;
            min = mod;
        }


    }
}
